﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Bootstrap.MVC.Utils;

namespace Bootstrap.MVC.Widgets
{
    public class ButtonFactory
    {
        private readonly ButtonGroupModel parent;

        public ButtonFactory(ButtonGroupModel parent)
        {
            Guard.IsNotNull(parent, "parent");
            
            this.parent = parent;
            
        }

        public virtual ButtonBuilder Add()
        {
            var model = new ButtonModel();
            parent.Buttons.Add(model);

            return new ButtonBuilder(model);
        }
    }
}
